# -*- coding: utf-8 -*-
# @Time    : 2021/9/16 12:58
# @Author  : BrandonGT
# @FileName: 10_8_cats_and_dogs.py

FILE_CAT = "cats.txt"
FILE_DOG = "dogs.txt"
FILES = [FILE_CAT, FILE_DOG]


def file_reader(filename):
    try:
        with open(filename, "r") as f:
            contents = f.read()
    except FileNotFoundError:
        pass  # 取消注释，如果想要slient
        # print(f"File {filename} isn't exsist")
    else:
        print(contents.strip())

for file in FILES:
    file_reader(file)